/*
 * File Name: BaseTableModel.java
 *
 */

package co.edu.uniandes.intercon.client.model;

import java.util.List;

/**
 * Base to the <code>TableModel</code> objects of the application
 * 
 * @author Fabian Gutierrez [fagossa@gmail.com]
 */
public interface IBaseTableModel<E> {
    
    /**
     * Clears all record in the model
     */
    public void clearTable();
    
    /**
     * Retieves the record in the specified row
     * 
     * @param   row Row where the record is located
     * @return  Record in the specified row
     */
    public E getRecord(int row) ;
    
    /**
     * Sets the record in the specified row
     * 
     * @param row   Row where the record in going to be located
     * @param obj   Record to be set
     */
    public void setRecord(int row, E obj);
    
    /**
     * Sets the current records to be shown in the table
     * 
     * @param objects collection of <code>E</code> to be show in the table
     */
    public void setRecords(List<E> objects);

    /**
     * Add a record to show in the table
     * @param i
     * @param obs
     */
	public void addRecord(E obs);    
}
